package com.ego.order.feign;

import com.ego.common.util.Result;
import com.ego.order.to.ware.WareLockTo;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;

import javax.validation.Valid;

/**
 * @program: ego
 * @description: 远程仓库服务
 * @author: KamTang
 * @create: 2022-12-23 11:54
 **/
@FeignClient("ego-ware")
public interface WareFeign {
    /**
     * 查询有库存的SKU
     * @param lockTo @see
     * @return @see
     * @see WareLockTo
     * @see Result
     */
    @PostMapping("/ware/sku/lock")
    Result lock(@Valid @RequestBody WareLockTo lockTo);
}
